package today.rocky.boot.mongo.pojo;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDate;

/**
 * @version 1.0
 * @vlog:
 * @description:
 * @author: Rocky
 * @createDate: 2020/6/9 20:31
 */
@Data
@Document(collection = "book")
public class Book implements Serializable {
	@Id
	private String id;
	private String name;
	private String type;
	private String author;
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	private LocalDate publicationDate;
	private Integer edition;
	private String press;
}
